docs/build: Move install checks into individual build targets
authorAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 21 Apr 2015 15:47:05 +0000 (16:47 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Wed, 22 Apr 2015 13:47:44 +0000 (14:47 +0100)
commit74fcdb636e77ca2f3b6cf71c2aebcb8f6ad768cd
treee2005ac91cfc812e0dd3f778d2fdc114fe981755
parentd6e4d499f82449f7ee6bf280e2b256ea38187fb0
docs/build: Move install checks into individual build targets

For top-level targets which use more than a single program to produce content
(txt already, pdf once pandoc is supported), these current checks are
unsuitable.

By moving the the install checks to the rules which actually use the programs,
it is now possible to build a subset of a top-level target depending on the
installed programs.

As a bonus, it removes the need to recurse for txt, man-pages and pdf targets.

A side effect of this is that every individual source which cannot be
generated will have a specific message logged, giving the file and program.
As such, these message are updated to consistently report the target file
which was not generated.

Finally, update "ifdef foo" to "ifneq($(foo),)" to be more resilient to errors
caused by having foo defined as an empty string.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
docs/Makefile